package com.easy.easybook.service.impl;

import com.easy.easybook.dao.CategoryMapper;
import com.easy.easybook.entity.Category;
import com.easy.easybook.service.CategoryService;
import com.easy.easybook.service.impl.base.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author http://zouyujie.top
 * @date 2021/12/19 11:53
 */
@Service
public class CategoryServiceImpl extends ServiceImpl<CategoryMapper, Category> implements CategoryService {
    @Autowired
    CategoryMapper categoryMapper;
    @Override
    public int update(Category category, Integer id) {
        return categoryMapper.update(category.getName(), id);
    }
}
